<%--
  Created by IntelliJ IDEA.
  User: Shirly
  Date: 2016/12/5
  Time: 15:06
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>上传文件</title>
</head>
<body>
<form action="upload.jsp" id="form1" name="form1" encType="multipart/form-data" method="post" target="hidden_frame">
    <input type="file" id="file" name="file" style="width:450">
    <input type="submit" value="上传文件"><span id="msg"></span>
    <br>
    <font color="red">支持JPG,JPEG,GIF,BMP,SWF,RMVB,RM,AVI文件的上传</font>
    <iframe name='hidden_frame' id="hidden_frame" style='display:none'></iframe>
</form>

</body>
</html>

<script type="text/javascript">
    function callback(msg) {
        document.getElementById("file").outerHTML = document.getElementById("file").outerHTML;
        document.getElementById("msg").innerHTML = "<font color=red>" + msg + "</font>";
    }
</script>
</body>
</html>
